package com.hhh.springai_test.model.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class CommentVO {
    /**
     * 主键
     */
    private Long id;


    /**
     * 评论目标id(图书id或帖子id)
     */
    private Long targetid;

    /**
     * 评论目标类型(0:图书 1:帖子)
     */
    private Integer targettype;

    /**
     * 评论内容
     */
    private String content;

    /**
     * 评论时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date commenttime;

    /**
     * 用户信息
     */
    private UserVo userInfo;

    private List<CommentReplyVO> commentReplies;

} 